package com.way.Java多线程编程核心技术v2.chapter02_对象及变量的并发访问._2_1_synchronized同步方法.重写方法不使用synchronized;

/**
 * @author 魏彪
 */
public class Test {

    public static void main(String[] args) {
        Sub sub = new Sub();

        ThreadA a = new ThreadA(sub);
        a.setName("A");
        a.start();

        ThreadB b = new ThreadB(sub);
        b.setName("B");
        b.start();
    }
}
